package com.logistics.sequence.entity.domain;

import java.io.Serializable;

import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 
 * </p>
 *
 * @author zhiyu.fan
 * @since 2024-05-16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("sys_sequence")
public class Sequence implements Serializable {

    private static final long serialVersionUID = 1L;

    private String name;

    private Integer currentValue;

    public  Sequence(String name, Integer currentValue){
        this.name = name;
        this.currentValue = currentValue;
    }

    public static Sequence build(String name, Integer currentValue){
        return new Sequence(name, currentValue);
    }
}
